package com.tencent.bk.sdk.iam.exception;

public class IamException extends RuntimeException {
    private final long errorCode;
    private final String errorMsg;

    public IamException(long errorCode, String errorMsg) {
        super("IAM Exception:" + errorCode + "|" + errorMsg);
        this.errorCode = errorCode;
        this.errorMsg = errorMsg;
    }

    public IamException(long errorCode, String errorMsg, Throwable cause) {
        super("IAM Exception:" + errorCode + "|" + errorMsg, cause);
        this.errorCode = errorCode;
        this.errorMsg = errorMsg;
    }

    public long getErrorCode() {
        return this.errorCode;
    }

    public String getErrorMsg() {
        return this.errorMsg;
    }
}
